from django.conf.urls import include, url

# https://blog.csdn.net/aduocd/article/details/60138982
# Django1.10中没有了patterns以后

urlpatterns = [
    url(r'^login/$', include('UserManage.views.user.LoginUser'), name='loginurl'),
    url(r'^logout/$', include('UserManage.views.user.LogoutUser'), name='logouturl'),

    url(r'^user/add/$', include('UserManage.views.user.AddUser'), name='adduserurl'),
    url(r'^user/list/$', include('UserManage.views.user.ListUser'), name='listuserurl'),
    url(r'^user/edit/(?P<ID>\d+)/$', include('UserManage.views.user.EditUser'), name='edituserurl'),
    url(r'^user/delete/(?P<ID>\d+)/$', include('UserManage.views.user.DeleteUser'), name='deleteuserurl'),

    url(r'^user/changepwd/$', include('UserManage.views.user.ChangePassword'), name='changepasswordurl'),
    url(r'^user/resetpwd/(?P<ID>\d+)/$', include('UserManage.views.user.ResetPassword'), name='resetpasswordurl'),

    url(r'^role/add/$', include('UserManage.views.role.AddRole'), name='addroleurl'),
    url(r'^role/list/$', include('UserManage.views.role.ListRole'), name='listroleurl'),
    url(r'^role/edit/(?P<ID>\d+)/$', include('UserManage.views.role.EditRole'), name='editroleurl'),
    url(r'^role/delete/(?P<ID>\d+)/$', include('UserManage.views.role.DeleteRole'), name='deleteroleurl'),

    url(r'^permission/deny/$', include('UserManage.views.permission.NoPermission'), name='permissiondenyurl'),

    url(r'^permission/add/$',include('UserManage.views.permission.AddPermission'), name='addpermissionurl'),
    url(r'^permission/list/$', include('UserManage.views.permission.ListPermission'), name='listpermissionurl'),
    url(r'^permission/edit/(?P<ID>\d+)/$', include('UserManage.views.permission.EditPermission'), name='editpermissionurl'),
    url(r'^permission/delete/(?P<ID>\d+)/$', include('UserManage.views.permission.DeletePermission'), name='deletepermissionurl'),
]
